﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using MandalaySoft.Common;

namespace SIMS.BL
{
    public class School
    {
        public int SchoolID { get; set; }

        public string SchoolName { get; set; }
        public string ShortName { get; set; }
        public string Address { get; set; }
        public string City { get; set; }
        public string State { get; set; }
        public string PostalCode { get; set; }
        public string Telephone { get; set; }
        public string PrincipleName { get; set; }
        public string FaxLine { get; set; }
        public string EmailAddress { get; set; }
        public string WebsiteUrl { get; set; }
        public decimal BaseGradeScale { get; set; }
        public string SchoolLogoUrl { get; set; }
        public bool IsActive { get; set; }
        
        public int CreatedBy { get; set; }
        public string CreatedByName { get; set; }
        public DateTime CreatedDate { get; set; }

        public int ModifiedBy { get; set; }
        public string ModifiedByName { get; set; }
        public DateTime ModifiedDate { get; set; }

        public MyError Error { get; set; }

        public School()
        {
            ClearFields();
        }

        private void ClearFields()
        {
            SchoolID = -1;
            SchoolName = string.Empty;
            ShortName = string.Empty;
            Address = string.Empty;
            City = string.Empty;
            State = string.Empty;
            PostalCode = string.Empty;
            Telephone = string.Empty;
            PrincipleName = string.Empty;
            FaxLine = string.Empty;
            EmailAddress = string.Empty;
            WebsiteUrl = string.Empty;
            BaseGradeScale = 0.000m;
            SchoolLogoUrl = string.Empty;
            IsActive = false;
            CreatedBy = -1;
            CreatedByName = string.Empty;
            CreatedDate = new DateTime(1900, 1, 1);
            ModifiedBy = -1;
            ModifiedByName = string.Empty;
            ModifiedDate = new DateTime(1900, 1, 1);
            Error = new MyError();
        }
    }
}
